package com.neusoft.work.controller;

import com.neusoft.work.po.Customer;
import com.neusoft.work.po.CustomerCareLevel;
import com.neusoft.work.po.ResponseBean;
import com.neusoft.work.service.CustomerCareLevelService;
import com.neusoft.work.service.CustomerService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

import java.util.List;


@RestController
@RequestMapping("/CustomerCareLevelController")
public class CustomerCareLevelController {

    @Autowired
    private CustomerCareLevelService cclService;

    @GetMapping("/getCustomerCareLevel")
    public ResponseBean<CustomerCareLevel> getCustomerCareLevel(Integer customerId) {
        return cclService.getCustomerCareLevel(customerId);
    }

    @PostMapping("/addCustomerCareLevel")
    public ResponseBean<Integer> addCustomerCareLevel(CustomerCareLevel ccl) {
        return cclService.addCustomerCareLevel(ccl);
    }

    @PostMapping("/removeCareLevel")
    public ResponseBean<Integer> removeCareLevel(Integer customerId) {
        return cclService.removeCareLevel(customerId);
    }
}
